Plotly example

Daniel Abreu

20/02/2023

Create a scatterplot of mpg vs. hp with color based on number of cylinders

This code creates a scatterplot of miles per gallon (mpg) vs. horsepower (hp) with color indicating the number of cylinders in the car. The plot is interactive, allowing you to hover over points for more information and zoom in/out.